//
//  BKHttpRequestCache.h
//  iLookForiPad
//
//  Created by baboy on 13-2-28.
//  Copyright (c) 2013年 baboy. All rights reserved.
//

#import <Foundation/Foundation.h>
#ifndef _BKHttpRequestCacheHandler_
    #define _BKHttpRequestCacheHandler_

typedef enum _BKHttpRequestCachePolicy {
    
    // no cache
	BKHttpRequestCachePolicyNone = 0,
	// The the request write to the cache
	BKHttpRequestCachePolicyCached = 1,
    // load if not cached
    BKHttpRequestCachePolicyLoadIfNotCached = 1<<1 | BKHttpRequestCachePolicyCached,
    //read cache if load failed
	BKHttpRequestCachePolicyFallbackToCacheIfLoadFails = 1<<2 | BKHttpRequestCachePolicyCached,
}BKHttpRequestCachePolicy;



extern NSString * getHttpRequestCacheFilePath(NSURL *url) ;
extern NSData * getHttpRequestCacheFileData(NSURL *url);

#endif
